﻿// $Id: RM.cs 64 2008-05-06 18:29:47Z nvivo $

using System.IO;
using System.Reflection;
using System.Xml.Schema;

namespace DBLGen
{
    internal class RM
    {
        public static XmlSchema LoadSchema(string resourceName)
        {
            Assembly a = Assembly.GetExecutingAssembly();

            XmlSchema schema;

            using (Stream s = a.GetManifestResourceStream(resourceName))
            {
                schema = XmlSchema.Read(s, null);
                s.Close();
            }

            return schema;
        }
    }
}
